package com.info.zhiduoduo.pay.sdk.zhaoshangbank.model.common.query;

import com.info.zhiduoduo.common.utils.DateUtil;
import com.info.zhiduoduo.pay.formbean.zhaoshangbankpay.QueryPayResultFormBean;
import com.info.zhiduoduo.repository.entity.pay.PaymentMerchant;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;

import java.util.ArrayList;
import java.util.Date;
import java.util.List;

@Data
@AllArgsConstructor
@NoArgsConstructor
@Accessors(chain = true)
public class Outline {

	//业务类型
	private String buscod;

	//业务模式
	private String busmod;

	//起始日期
	private String bgndat;

	//结束日期
	private String enddat;

	//日期类型
	private String datflg;   //默认为A

	//续传接口
	private String ctnkey;   //默认空

	public static List<Outline> ofList(QueryPayResultFormBean formBean, PaymentMerchant paymentMerchant){
		List<Outline> list = new ArrayList<>();
		Outline result = new Outline()
				.setBuscod("N03020")
				.setBusmod(paymentMerchant.getPatternCode())
				.setBgndat(formBean.getOrderTime())
				.setEnddat(formBean.getOrderTime())
				.setDatflg("A")
				.setCtnkey("");
		list.add(result);
		return list;
	}

}
